package cn.jingyuan.owl.model.paging;

import java.io.Serializable;

/**
 * 分页查询模型
 */
public class PageQueryModel<Q> implements Serializable {

    /** 当前页数 */
    protected Integer page = 1;

    /** 每页记录数 */
    protected Integer pageSize = 10;

    /** 查询参数 */
    protected Q params;

    public PageQueryModel() {}

    public Integer getPage() {
        return page;
    }

    public void setPage(int page) {
        this.page = page;
    }

    public Integer getPageSize() {
        return pageSize;
    }

    public void setPageSize(int pageSize) {
        this.pageSize = pageSize;
    }

    public Q getParams() {
        return params;
    }

    public void setParams(Q params) {
        this.params = params;
    }

    public PageModel getPageModel() {
        return new PageModel(page, pageSize);
    }

}
